package com.zenni.test;

import java.util.concurrent.TimeUnit;

import org.openqa.selenium.By;
import org.openqa.selenium.JavascriptExecutor;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.firefox.FirefoxDriver;
import org.openqa.selenium.firefox.FirefoxProfile;
import org.testng.annotations.Test;

public class testwithoutdependency {
	WebDriver driver = null;
	
	@Test
	public void testwithout() throws Exception{
		FirefoxProfile profile = new FirefoxProfile();
		profile.setPreference("webdriver.load.strategy", "unstable");
		driver = new FirefoxDriver(profile);
		driver.get("http://www.zennioptical.com");
		driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
		/*JavascriptExecutor js = (JavascriptExecutor)driver;
        js.executeScript("document.getElementsByClassName(\"nav-women\")[0].click()");*/
		driver.findElement(By.xpath("//ul[@id = 'main-nav']/li[@class = 'main-navigation hide show-sm']/ul/li[1]")).click();;
        Thread.sleep(3000);
        driver.quit();
	}
}
